Hands-On Reactive Programming with Reactor by Rahul Sharma

Hands-On Reactive Programming with Reactor by Rahul Sharma

Author:Rahul Sharma
Language: eng
Format: epub
Tags: COM051280 - COMPUTERS / Programming Languages / Java, COM051000 - COMPUTERS / Programming / General, COM011000 - COMPUTERS / Systems Architecture / General
Publisher: Packt Publishing
Published: 2018-09-29T07:21:28+00:00


Now, let's add a Mustache template to show the Fibonacci series. In this case, it would be beneficial to list the numbers as a simple HTML list, which is shown as follows:

<!DOCTYPE html>

<html>

<head>

<title>Reactor Sample</title>

<meta charset="UTF-8"/>

<meta name="viewport" content="width=device-width, initial-scale=1.0"/>

</head>

<body>

<section class="container">

{{#series}}

<div class="row">

{{.}}

</div>

{{/series}}

</section>

</body>

</html>

In the preceding HTML template, the following has occurred:

There is a series variable, containing a list of values.

The {{#series}} {{/series}} syntax iterates through the list, providing individual values.

The value is then rendered by using the {{.}} syntax in an HTML ?div> tag.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.